package org.ecloud.biz.api.service;

import java.util.List;

import org.beetl.sql.core.engine.PageQuery;
import org.ecloud.biz.api.mapper.ApiMapper;
import org.ecloud.biz.api.model.ApiPo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

@Repository
public class ApiQueryService {
	
	@Autowired
	private ApiMapper mapper;
	
	public void query(PageQuery<ApiPo> pageQuery){
		mapper.templatePage(pageQuery);
	}

	public List<ApiPo> findAll(){
        return mapper.all();
	}

    public ApiPo get(Long id){
    	return mapper.unique(id);
    }

}
